import { Entity, Column, PrimaryGeneratedColumn } from 'typeorm';
import { NoticeIsDeleteEnum, NoticeReadTypeEnum, NoticeTypeEnum } from './notices.enum';
import { EnumRejectReasonType } from '../rejectReason/rejectReason.enum';

@Entity()
export class Notices {
  @PrimaryGeneratedColumn()
  id: number;

  @Column({ name: 'video_id' })
  video_id: number;
  
  @Column({ name: 'answer_id' })
  answer_id: number;

  @Column({ name: 'wx_user' })
  wx_user: string;

  @Column({ name: 'create_time' })
  create_time: Date;

  @Column({ name: 'type' })
  type: NoticeTypeEnum;

  @Column({ name: 'is_read' })
  is_read: NoticeReadTypeEnum;

  @Column({ name: 'is_delete' })
  is_delete: NoticeIsDeleteEnum;

  @Column({ name: 'check' })
  check: number;
  
  @Column({ name: 'profit_refund_id' })
  profit_refund_id: number;

  @Column({ name: 'reject_reason' })
  reject_reason: string;

  @Column({ name: 'effect_time' })
  effect_time: Date;

  @Column({ name: 'profit_time' })
  profit_time: Date;

  @Column({ name: 'content' })
  content: string;
}
